<template>
    <div class="param-view">
        <div class="label">{{label}}</div>
        <div class="input">
            <input class="text" :class="{err}" type="text" :value="word" :placeholder="tip" v-if="!mult" @change="onWord">
            <textarea class="lines" :value="word" :placeholder="tip" v-if="mult" @change="onWord"></textarea>
        </div>
    </div>
</template>
<script>

export default {
    props: {
        label: String,
        tip: String,
        mult: Boolean,
        word: String,
        err: Boolean
    },
    data() {
        return {
            
        }
    },
    methods: {
        onWord(e) {
            console.log(e, "onWord");
            this.$emit("word", e.target.value);
        },
    },
}
</script>

<style lang="less" scoped>
@import url(./index.less);
</style>